create external table jms_dm.dm_network_entry_port_aging_sign_network_sum_dt
(
end_agent_code            string COMMENT '末端代理区code' ,
end_agent_name            string COMMENT '末端代理区' ,
end_center_code           string COMMENT '末端中心code' ,
end_center_name           string COMMENT '末端中心' ,
end_franchisee_code       string COMMENT '末端加盟商' ,
end_franchisee_name       string COMMENT '末端加盟商' ,
final_sign_network_code   string COMMENT '末端网点' ,
final_sign_network_name   string COMMENT '末端网点' ,
order_source_code         string COMMENT '订单来源code' ,
order_source_name         string COMMENT '订单来源名字' ,
is_common                 string COMMENT '是否共配' ,
need_departure_sum        string COMMENT '应接件件数' ,
on_time_departure_sum     string COMMENT '准点接件个数' ,
over_time_departure_sum   string COMMENT '延误接件个数' ,
on_time_arrival_sum       string COMMENT '准点到件数' ,
over_time_arrival_sum     string COMMENT '延误到件数' ,
need_deliver_sum          string COMMENT '应出仓总量' ,
on_time_deliver_sum       string COMMENT '准点出仓总量' ,
over_time_deliver_sum     string COMMENT '延误出仓总量' ,
aging_sign_on_time_sum    string COMMENT '准点签收总量' ,
aging_sign_over_time_sum  string COMMENT '延误签收总量' ,
date_time string comment'业务日期'
)
comment '网点进港时效网点汇总'
PARTITIONED BY ( dt string COMMENT '时间分区')
stored as parquet
LOCATION '/dw/hive/jms_dm.db/external/dm_network_entry_port_aging_sign_network_sum_dt'
TBLPROPERTIES (     'discover.partitions' = 'false',  'parquet.column.index.access' = 'true');

 alter table jms_dm.dm_network_entry_port_aging_sign_network_sum_dt add columns (
    yizhan_delay int comment'驿站延误',  --
    guiji_delay int comment'柜机延误',   --
    shsm_delay int comment'送货上门延误',   --
    active_sign_on_time_sum int comment'实际签收准点总量',  --
    active_sign_over_time_sum int comment'实际不准点签收总量',
    deadline_signing_time  string comment '截止签收时间',
    unsign_count  int comment '未签收汇总',
    difficult_over_time_count   int comment '问题件汇总'
     )cascade ;